这里是今天你将要创建的假日贺卡示例!

  • 按空格键使雪花飞过!
  • 点击精灵来查看问候语!
  • 点击 提交 下一步 开始创造自己的贺卡。

To navigate the page using the TAB key, first press ESC to exit the code editor.

stage.set_background("winter") sprite = codesters.Sprite("person12") sprite.go_to(-125, -50) #my_sprite.say("I can't wait for the holidays!") frosty = codesters.Sprite("snowman") frosty.go_to(100, -100) snow = codesters.Sprite("snowflake3") snow.go_to(100, 75) greeting = codesters.Text("Happy Holidays!") greeting.go_to(0, 200) greeting.set_color("yellow") def click(sprite): sprite.say("I hope your holidays are great!") sprite.move_up(100) sprite.turn_left(360) sprite.move_down(100) # add other actions... sprite.event_click(click) def space_bar(): snow.set_x_speed(5) snow.set_y_speed(2) stage.event_key("space", space_bar)
  • Run Code
  • 提交作品
  • 下个活动
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)